// Time Format for CRYSTAL Reports (24:00:00 format) // // Convert MS ACCESS Time to Whole Number NumberVar TotWholeNbr:={Time.Time}*100000000; // Calculate Hours NumberVar Hours:=Truncate(TotWholeNbr/4166666.64); // Calculate Minutes NumberVar Mins:=Truncate((TotWholeNbr-(Hours*4166666.64))/69444.444); // Calculate Seconds NumberVar Secs:=Truncate((TotWholeNbr-((Hours*4166666.64)+(Mins*69444.444)))/1157.4074); // Set Hour String If Hours<10 Then StringVar HH:="0"+ToText(Hours) Else StringVar HH:=ToText(Hours); // Set Minute String If Mins<10 Then StringVar MM:="0"+ToText(Mins) Else StringVar MM:=ToText(Mins); // Set Seconds String If Secs<10 Then StringVar SS:="0"+ToText(Secs) Else StringVar SS:=ToText(Secs); // Output Time HH[1 to 2]+":"+MM[1 to 2]+":"+SS[1 to 2];